import java.util.Formatter;
import java.util.Scanner;

public class test2 {

    public static void main(String[] args) {
        Scanner cin=new Scanner(System.in);

        double x=cin.nextDouble();

        String s1=(new Formatter()).format("%.2f",x).toString();

        System.out.println(s1);

        String s2=String.format("%.3f",x);

        System.out.println(s2);
    }
}
